import 'package:flutter_test/flutter_test.dart';
import 'package:sow_app/repository/ajax_captcha_image_repository.dart';
import 'package:sow_app/repository/ajax_rest_client.dart';
import 'package:sow_app_core/sow_app_core.dart';

void main() async {
  test(
    "should return CaptchaImageModel when invoke get()",
    () async {
      // arrange

      // act
      var result = await AjaxCaptchaImageRepository(AjaxRestClient()).get();
      // assert
      expect(result, isA<Captcha>());
      expect(result.image, isNotEmpty);
      expect(result.image.length, greaterThan(1000));
    },
  );
}
